package com.woniuxy.test05;

import org.junit.Test;

import java.io.IOException;
import java.util.Calendar;

/**
 * @Author author
 * @Create 2023-09-15 9:46
 */
public class MyTest {

    @Test
    public void test01() throws IOException {
        Singleton s1 = Singleton.createInstance();
        Singleton s2 = Singleton.createInstance();
        Singleton s3 = Singleton.createInstance();
        System.out.println(s1==s2);
        System.out.println(s1==s3);

        Calendar c1 = Calendar.getInstance();
        Calendar c2 = Calendar.getInstance();
        System.out.println(c1==c2);
    }

}


